package java56_6.ch5;

import java56_6.Cat;
import java56_6.Pet;

public class CatTest {

	public static void main(String[] args) {
		// int j = 100, i = 100;
		// System.out.println(i == j);
		// Object：toString,equals
		Pet c = new Cat("波斯猫", 9, "母");
		System.out.println(c);
		Cat c2 = new Cat("波斯猫", 19, "公");
		System.out.println(c == c2);
		// 逻辑上相等
		System.out.println(">>>");
		boolean f = c2.equals(c);
		System.out.println(f);
	}

}
